package com.zhuss.advice.proposalSon;

import com.zhuss.bean.bo.advice.proposalSon.CreateProposalSonBo;
import com.zhuss.common.OperateService;
import com.zhuss.common.Processor;
import com.zhuss.exception.WpsException;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Qualifier;
import org.springframework.stereotype.Component;

/**
 * @Author: zhushanshuo
 * @Date: 2020/3/6 9:42
 */
@Component("proposalSonOperateService")
public class ProposalSonOperateService implements OperateService<Void, Object> {

    @Autowired
    @Qualifier("proposalSonCreate")
    private Processor<Object, CreateProposalSonBo> proposalSonCreate;

    @Override
    public Void create(Object o) throws WpsException {
        CreateProposalSonBo bo = (CreateProposalSonBo)o;
        proposalSonCreate.process(bo);
        return null;
    }

    @Override
    public Void update(Object o) throws WpsException {
        return null;
    }

    @Override
    public Void delete(Object o) throws WpsException {
        return null;
    }
}
